import Vue from 'vue'
import App from './App.vue'
import router from './router/index'
import store from './store'
import qs from 'qs'
import 'amfe-flexible' // rem 适配
// import vConsole from './assets/vconsole'
import ssPicker from './components/popupPicker.vue'
import popupPicker from './components/popPicker.vue'

// vant 按需引用
import vant from './ui/vant'
import { Toast, Dialog } from 'vant'
import './permission' // permission control

import loading from './components/common/loading/index'
Vue.use(vant)
Vue.component('ssPicker', ssPicker)
Vue.component('popupPicker', popupPicker)
Vue.config.productionTip = false
Vue.prototype.$toast = Toast
Vue.prototype.$Dialog = Dialog
Vue.prototype.$loading = loading // 我的加载框
Vue.prototype.$qs = qs
Vue.config.ignoredElements = ['wx-open-launch-app', 'wx-open-launch-weapp']
// import globalComponents from './assets/commonJs/globalComponents'  //全局组件配置文件
// Vue.prototype.vConsole = vConsole
Vue.prototype.aesKey = 'tecsun#2022abcde' // 密钥
Vue.prototype.aesKeyIv = 'edcba2202#nuscet' // 偏移量

// router.beforeEach((to, from, next) => {
//   window.document.title = to.meta.title // 页面标题
//   next()
// })

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
